<%@ attribute name="id"  required="true"%>

<script type="text/javascript">

	function somenteNumeros(input, event) {
		if ((event.keyCode < 48) || (event.keyCode > 57))
			event.returnValue = false;
	}

	function formataCarga(campo, tammax, teclapres) {

		var tecla = teclapres.keyCode;
		var vr = campo.value;
		vr = vr.replace("/", "");
		vr = vr.replace(",", "");
		vr = vr.replace(".", "");
		tam = vr.length;

		if ((tecla >= 48) && (tecla <= 57) || (tecla >= 96 && tecla <= 105)
				|| (tecla == 8)) {
			if (tam < 3) {
				campo.value = vr;
			}
			if (tam >= 3) {
				campo.value = vr.substr(0, tam - 2) + '.'
						+ vr.substr(tam - 2, 2);
			}
		}
	}
	
</script>
<input type="text" class="${id}" name="${id}" />